﻿using Direct.IDAL.Manager;
using DirectSell.Model.Manager;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DirectSell.DAL.Manager
{
    /// <summary>
    /// 后台管理仓储基类
    /// </summary>
    public class BaseManagerRepository:AbsRepository, IBaseManagerRepository
    {

        #region 查询出该管理员信息
        /// <summary>
        /// 查询出该管理员信息
        /// </summary>
        /// <returns></returns>
        public Managers QueryManagerInfo(string managerCode)
        {
            StringBuilder sb = new StringBuilder();
            sb.Append(" SELECT * FROM Managers  ");
            sb.AppendFormat(" WHERE ManagerCode='{0}'  ",managerCode);
            return base.Query<Managers>(sb.ToString()).FirstOrDefault();
        }
        #endregion

    }
}
